<template>
<view class="g_content">
    <view class="dis_f_c_c">
    <u-tabs :list="tabList" :current="currentIndex" lineColor="#27AC2F" @click="handleTab"></u-tabs>
    </view>
    <s-goods :goodsList="list" :isReject="true" :isToUp="true" @handleToDetail="handleToDetail" @updataData="updateData"></s-goods>
    <view v-if="list.length==0" class="m_t_50">
      <s-empty text="暂无数据" mode="list"></s-empty>
    </view>
            <!-- 授权弹窗 -->
        <s-auth-modal />
</view>
</template>
<script>
import {myMixins} from "@/mixins/myMixins";
import {getInformationList2Api} from "@/sheep/api";
export default {
    mixins:[myMixins],
    name: "mySend",
    data() {
        return {
            tabList:[{name:'审核中'},{name:'已通过'},{name:'已驳回'},],
            currentIndex:0,
            list:[],
        }
    },
    onShow() {
        this.updateData()
    },
    methods:{
        handleToDetail(item){
            uni.navigateTo({
                url: '/pages/info/index?userId='+item.userId
            })
        },
        getList(){
            this.queryObj.shzt = this.currentIndex+1
            getInformationList2Api(this.queryObj).then(res=>{
                this.list = this.list.concat(res.rows)
                this.total = res.total
                if (this.queryObj.pageNum*this.queryObj.pageSize<this.total){
                    this.status = 'loadmore'
                }else{
                    this.status = 'nomore'
                }
                uni.stopPullDownRefresh()
            })
        },
        handleTab(e){
            this.currentIndex=e.index
            this.updateData()
        }
    }
}
</script>

<style scoped lang="scss">

</style>
